package pub.developers.forum.api.response.inform;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import pub.developers.forum.api.response.comment.CommentPageResponse;
import pub.developers.forum.api.response.user.UserInfoResponse;

import java.util.Date;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class InformPageResponse {

    private long id;

    private Date createAt;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String content;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private long replyId;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long views;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long approvals;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long comments;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private CommentPageResponse.Commentator author;    // 作者

    private String type; // 1 文章 2 评论

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String htmlContent;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String markdownContent;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String images;

    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String headImg;


    private UserInfoResponse informer;  // 举报者


    private Long authorId;

    private String authorNickname;

    private String authorAvatar;


}
